php forum
php mysql forum
php mysql smarty
 
Page 3 of 4 < 1 2 3 4 >
Topic Options
#313597 - 03/18/07 01:57 AM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ
Originally Posted By: Gizmo
Could you paste me exactly what you put in the ubbcode block for the spoiler tag? What it looks like is that you're missing the ),

All I did was type
Click to reveal..
test
smirk

The error came up in Post Preview - I never actually posted it. Not sure if that makes a difference...

_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
#313600 - 03/18/07 04:25 AM Re: [7.x] UBB Spoiler Tags [Re: jgeoff]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
well, the error is with the ubbcode insert in the lib file; i need to know exactly what you inserted to troubleshoot it lol
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313603 - 03/18/07 11:54 AM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ

Sorry, I misunderstood what you were asking blush

I put this in libs/ubbthreads.inc.php, the same code you provided, after the email line as directed:
Code:
array( "#\[spoiler\](.+?)\[/spoiler\]#i", "<div class=\"ubbcode-block\"><div class=\"ubbcode-header\">Warning, Spoiler: <input type=\"button\" class="form-button" value=\"Show\" onclick=\"if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }\" /></div><div class=\"ubbcode-body\"><div style=\"display: none;\">\\1</div></div></div>" ),


And not only do I get the following error, but it prevents the entire forum from loading up. I get a white screen with:
Quote:

Parse error: syntax error, unexpected T_STRING, expecting ')' in /home2/gbb/public_html/threads/libs/ubbthreads.inc.php on line 1011


confused
_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
#313609 - 03/18/07 04:17 PM Re: [7.x] UBB Spoiler Tags [Re: jgeoff]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
I'm certainly hoping you're posting the content of your file vs the first post in this thread lol...

I don't honestly see why you'd be getting this issue; could you email me your libs/ubbthreads.inc.php so I can take a look? james[at]virtualnightclub[dot]net.
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313618 - 03/19/07 12:08 PM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ

Of course I copied/pasted it from my file - lol - but I'll email it to you anyway... laugh
_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
#313619 - 03/19/07 01:27 PM Re: [7.x] UBB Spoiler Tags [Re: jgeoff]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Gizmo,

This looked like a cool addon so I tried it as well, I got the same error. I simply copied/pasted the one line in your first post and saved the file. I got the same error and removed it.

Fred

Top
#313620 - 03/19/07 01:33 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Found the error. You were missing the escape characters for the added "class" part.

Should be:
Code:
array( "#\[spoiler\](.+?)\[/spoiler\]#i", "<div class=\"ubbcode-block\"><div class=\"ubbcode-header\">Warning, Spoiler: <input type=\"button\" class=\"form-button\" value=\"Show\" onclick=\"if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }\" /></div><div class=\"ubbcode-body\"><div style=\"display: none;\">\\1</div></div></div>" ),


Fred

Top
#313621 - 03/19/07 03:10 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Hmmm, I added everything like in the instructions, but I can't get the window to "popup."

I did change void(x) to void (0) to match the others as in:
Code:
<a href="javascript: void(0)" onclick="DoPrompt('spoiler');" title="Spoiler" alt="Spoiler"><img id="spoiler" onmouseover="raiseButton(this.id);" onmouseout="normalButton(this.id);" onmousedown="lowerButton(this.id);" class="markup_panel_normal_button" src="{$config.BASE_URL}/images/{$style_array.markup_panel}/spoiler.gif" /></a> 



Still no dice.

Top
#313622 - 03/19/07 03:39 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ

Good eye, Fred! Mine's working properly now... cool
It was the class=\"form-button\" missing the slashes...

_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
#313623 - 03/19/07 03:46 PM Re: [7.x] UBB Spoiler Tags [Re: jgeoff]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Are you using the markup panel? I have gotten the spoiler part to work, but not the markup panel. It shows the button, will highlight it and when you mouse over it, it says "spoiler" and at the bottom (status bar) you can see where it will call javascript like the others, but when you click the button nothing happens.

Top
#313624 - 03/19/07 03:57 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Weird, I had to exit out of IE all together and come back and now the spoiler button is working...

FYI


Top
#313625 - 03/19/07 04:02 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ

No, I didn't include it in the markup panel, but glad yours is working now... cool


_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
#313627 - 03/19/07 04:11 PM Re: [7.x] UBB Spoiler Tags [Re: jgeoff]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Oh, one more FYI, the gif file is about 1 or 2 pixels too big (tall-height).

Edit: I removed a pixel from the top and it matches up now.


Attachments
2375-Spoiler.gif




Edited by Fred Johnson (03/19/07 04:19 PM)

Top
#313628 - 03/19/07 04:21 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
The markup panel addon should work, i tested it like once then removed it from my board.

As for the class, blaime it on me... I added that like a week or so ago and just updated it here vs taking from my live board lol... I'll update first post now...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313629 - 03/19/07 04:23 PM Re: [7.x] UBB Spoiler Tags [Re: Cuervo]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
Ok, first post updated.

As for the markup panel working after you closed your browser; your browser was caching the lib file.

AS for the gif being "too big", I'll get it updated to freds; the one I supplied was the ! which should be the proper size.
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313631 - 03/19/07 05:22 PM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Gizmo,

Well, I thought it was all working, but I have found out that now if someone uses a spoiler tag in a post no one can edit either their post or any post in the topic (even if posted after the spoiler tag post).

Any ideas?

Top
#313632 - 03/19/07 05:40 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
I don't see how it'd happen actually, could you link me to an example of this?
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313633 - 03/19/07 05:47 PM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
Fred Johnson Offline
Junior Member

Registered: 07/14/06
Posts: 21
Sent you a PM.

Click to reveal..
Test


Can someone else with this mod installed post a spoiler in a topic and then try to edit their post?

Does it let you?

Fred


Edited by Fred Johnson (03/19/07 06:03 PM)

Top
#313634 - 03/19/07 06:53 PM Re: [7.x] UBB Spoiler Tags [Re: Fred Johnson]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
Allows me just fine on 3 installs, hence why i dont see why this would error...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#313635 - 03/19/07 07:32 PM Re: [7.x] UBB Spoiler Tags [Re: Gizmo]
jgeoff Offline
Power User

Registered: 04/05/01
Posts: 97
Loc: NJ

No problems here. It's a tag like any other, so doesn't make sense to me, either... confused
_________________________
GangsterBB.NET (Ver. 7.3)
2007 Content Rulez Contest - Honorable Mention
UBB.classic 6.7.2 - RIP
Browser: Firefox 2.0

Top
Page 3 of 4 < 1 2 3 4 >



Moderator:  sirdude 
Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks